home *** CD-ROM | disk | FTP | other *** search
- package Code.LIB.SOUND
- {
- import Code.LIB.COMPONENTS._gy596;
- import Code.LIB._cg33;
- import Code.OPTIONS._gs337;
- import flash.events.MouseEvent;
- import flash.media.Sound;
- import flash.media.SoundChannel;
- import flash.media.SoundMixer;
- import flash.media.SoundTransform;
- import flash.utils.*;
-
- public class _bu111
- {
- public static var iMusic:_gy596;
-
- private static var savedSoundsV:Number;
-
- public static var iSound:_gy596;
-
- private static var iList:_gw228;
-
- private static var iMusikVolume:Number;
-
- private static var savedMusicV:Number;
-
- private static var iSounds:Array = new Array();
-
- private static var iSTransform:SoundTransform = new SoundTransform();
-
- private static var iMTransform:SoundTransform = new SoundTransform();
-
- private static var iMChannel:SoundChannel = new SoundChannel();
-
- private static var iSChannel:SoundChannel = new SoundChannel();
-
- private static var iSoundVolume:Number = 1;
-
- public static var iMusPlaying:Boolean = false;
-
- public function _bu111()
- {
- super();
- }
-
- public static function set _yt336(param1:Number) : void
- {
- iMusikVolume = param1;
- iMTransform.volume = iMusikVolume;
- iMChannel.soundTransform = iMTransform;
- if(iMusikVolume == 0)
- {
- iMusic.State = _gy596.stOff;
- }
- else
- {
- iMusic.State = _gy596.stOnn;
- }
- if(_cg33._ss555)
- {
- _cg33._ss555[1].prMVolume = param1;
- }
- }
-
- private static function _hd374(param1:String) : Sound
- {
- var _loc2_:Array = null;
- for each(_loc2_ in iSounds)
- {
- if(_loc2_[0] == param1)
- {
- return Sound(_loc2_[1]);
- }
- }
- return null;
- }
-
- public static function get _uk57() : Number
- {
- return iSoundVolume;
- }
-
- public static function get _yt336() : Number
- {
- return iMusikVolume;
- }
-
- public static function _wu209(param1:String, param2:Boolean = false) : void
- {
- var _loc3_:Sound = null;
- iSTransform.volume = iSoundVolume;
- iMTransform.volume = iMusikVolume;
- _loc3_ = _hd374(param1);
- if(!_loc3_)
- {
- return;
- }
- if(param2)
- {
- if(iMusPlaying)
- {
- return;
- }
- iMusPlaying = true;
- iMChannel.stop();
- iMChannel = _loc3_.play(0,999,iMTransform);
- }
- else
- {
- iSChannel = _loc3_.play(0,0,iSTransform);
- }
- }
-
- public static function _pp317(param1:Array) : void
- {
- var _loc2_:Array = null;
- var _loc3_:Array = null;
- var _loc4_:Sound = null;
- iSound = new _gy596(_gs337.TSpeakerOnn,_gs337.TSpeakerOff);
- iSound._vq458 = 604;
- iMusic = new _gy596(_gs337.TMusicOnn,_gs337.TMusicOff);
- iMusic._vq458 = 574;
- iSound._vg471 = 12;
- iMusic._vg471 = 13;
- iSound.addEventListener(MouseEvent.MOUSE_DOWN,_ld216);
- iMusic.addEventListener(MouseEvent.MOUSE_DOWN,_ld216);
- iSTransform.volume = iSoundVolume;
- iMTransform.volume = iMusikVolume;
- _loc2_ = iSounds;
- for each(_loc3_ in param1)
- {
- _loc4_ = new _loc3_[1]() as Sound;
- iSounds.push([_loc3_[0],_loc4_]);
- }
- _bu111.iList = new _gw228(iSTransform);
- }
-
- public static function _um807(param1:String) : void
- {
- _bu111.iList.add(_hd374(param1));
- }
-
- public static function set _uk57(param1:Number) : void
- {
- iSoundVolume = param1;
- if(_cg33._ss555)
- {
- _cg33._ss555[1].prSVolume = param1;
- }
- if(iSoundVolume == 0)
- {
- iSound.State = _gy596.stOff;
- }
- else
- {
- iSound.State = _gy596.stOnn;
- }
- }
-
- public static function _ld216(param1:MouseEvent) : void
- {
- switch(param1.target)
- {
- case iMusic.iButton._en365:
- if(iMusic.State == _gy596.stOnn)
- {
- savedMusicV = _yt336;
- _yt336 = 0;
- iMusic.State = _gy596.stOff;
- }
- else
- {
- _yt336 = !!savedMusicV ? savedMusicV : 0.7;
- iMusic.State = _gy596.stOnn;
- }
- _cg33._gk638();
- break;
- case iSound.iButton._en365:
- if(iSound.State == _gy596.stOnn)
- {
- savedSoundsV = _uk57;
- _uk57 = 0;
- iSound.State = _gy596.stOff;
- }
- else
- {
- _uk57 = !!savedSoundsV ? savedSoundsV : 0.7;
- iSound.State = _gy596.stOnn;
- }
- _cg33._gk638();
- }
- }
-
- public static function _gx822() : void
- {
- iMusPlaying = false;
- SoundMixer.stopAll();
- }
-
- public static function _nm154() : void
- {
- iSChannel.stop();
- }
- }
- }
-
-